package com.iter.devbox.servlet3;

import javax.servlet.ServletContextEvent;
import javax.servlet.ServletContextListener;
import javax.servlet.annotation.WebListener;

/**
 * 被 \@WebListener 标注的类必须实现以下至少一个接口：
 * ServletContextListener
 * ServletContextAttributeListener
 * ServletRequestListener
 * ServletRequestAttributeListener
 * HttpSessionListener
 * HttpSessionAttributeListener
 * 
 * @author hnylj
 *
 */
@WebListener(value="this is Listener...")
public class MyServletListener implements ServletContextListener {

	@Override
	public void contextInitialized(ServletContextEvent sce) {
		System.out.println("init context......");
	}

	@Override
	public void contextDestroyed(ServletContextEvent sce) {
		System.out.println("destroy context......");
	}
}
